home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MACD 5
/
MACD 5.bin
/
workbench
/
wb
/
czesc_4
/
shellbench
/
shellbench.install
< prev
next >
Wrap
Text File
|
1995-04-29
|
9KB
|
385 lines
; *************************************************************************
; ******************* SHELLBENCH INSTALLATION SCRIPT ********************
; *************************************************************************
;
; $VER: InstallShellBench 1.0 (30.4.95)
;
; Copyright ©1995 Nick Christie
;
; *************************************************************************
;
; Find out about program version, etc
; get version of SB in distribution
(set vernum-sb (getversion "ShellBench"))
(set ver-sb (/ vernum-sb 65536))
(set rev-sb (- vernum-sb (* ver-sb 65536) ) )
(set @default-dest "")
(set defsbdir "SYS:WBStartup")
(set libsdir "Libs:")
(set catsdir "Locale:Catalogs")
; if novice user-level, bump up to average
(if (= 0 @user-level)
(
(set @user-level 1)
(user 1)
)
)
(set old-user-level @user-level)
; ************************************************************************
; English strings
; ************************************************************************
(set default_lang 4)
(set #yes-msg "Yes")
(set #no-msg "No")
(set #bad-kick-msg "ShellBench requires AmigaOS 2.04 or better!")
(set #hello-msg
(cat
("Welcome to ShellBench V%ld.%ld\n\n" ver-sb rev-sb)
"This script will install ShellBench and "
"related files on your Amiga.\n\n"
"You will need to answer a few questions such as "
"where you would like the program installed.\n\n"
"If you do not wish to install ShellBench at this time, "
"select the 'Abort Install' button now. "
)
)
(set #sb-askdir-msg "Please select the directory to install ShellBench in.")
(set #keepicon-msg "Do you wish to keep your existing ShellBench icon?")
(set #keepicon-help
(cat
"If you select 'Yes', your existing ShellBench icon will not "
"be overwritten. If you select 'No', a new icon for ShellBench "
"will be installed."
)
)
(set #bgui-askdir-msg
(cat
"Select the directory to install bgui.library in. "
"(Will *not* overwrite any existing newer version.)"
)
)
(set #sbguide "ShellBench.guide")
(set #sbguide-ask-msg
(cat
"\nInstall ShellBench documentation?\n\n"
"(This is an AmigaGuide file, and you will be asked "
"for the directory in which to install it.)\n\n"
"I recommend installing this, and reading it too, "
"so that you know how to utilitise ShellBench to "
"its fullest."
)
)
(set #sbguide-askdir-msg
(cat
"\nPlease select the directory "
"to install ShellBench.guide in.\n"
)
)
(set #guide-help
(cat
"AmigaGuide is the Amiga's standard hypertext format.\n\n"
"If you have AmigaOS 3.0 or better, you can use MultiView "
"to read this documentation, otherwise you must use the AmigaGuide "
"program, which is available on AmiNet and Fred Fish disk #870.\n\n"
"Both of these viewer programs have a 'search path', a set "
"of directories they search for AmigaGuide documents. "
"You should place this guide somewhere in that path."
)
)
(set #locale-msg
(cat
"\nShellBench is localized, which means you may use "
"the program in several different languages. "
"Please choose your preferred languages.\n"
)
)
(set #locale-help
(cat
"These are the languages supported by ShellBench.\n\n"
"Simply specify the languages you prefer and the "
"required catalog files will be copied to the "
"Locale:Catalogs directory.\n\nThis feature is "
"only available under AmigaOS 2.1 and later."
)
)
; ************************************************************************
; xxxx strings - template for other languages
; ************************************************************************
(if (= @language "xxxx")
(
(set default_lang 4)
(set #yes-msg "Yes")
(set #no-msg "No")
(set #bad-kick-msg "ShellBench requires AmigaOS 2.04 or better!")
(set #hello-msg
(cat
("Welcome to ShellBench V%ld.%ld\n\n" ver-sb rev-sb)
"This script will install ShellBench and "
"related files on your Amiga.\n\n"
"You will need to answer a few questions such as "
"where you would like the program installed.\n\n"
"If you do not wish to install ShellBench at this time, "
"select the 'Abort Install' button now. "
)
)
(set #sb-askdir-msg "Please select the directory to install ShellBench in.")
(set #keepicon-msg "Do you wish to keep your existing ShellBench icon?")
(set #keepicon-help
(cat
"If you select 'Yes', your existing ShellBench icon will not "
"be overwritten. If you select 'No', a new icon for ShellBench "
"will be installed."
)
)
(set #bgui-askdir-msg
(cat
"Select the directory to install bgui.library in. "
"(Will *not* overwrite any existing newer version.)"
)
)
(set #sbguide "/Guides/xxxx/ShellBench.guide")
(set #sbguide-ask-msg
(cat
"\nInstall ShellBench documentation?\n\n"
"(This is an AmigaGuide file, and you will be asked "
"for the directory in which to install it.)\n\n"
"I recommend installing this, and reading it too, "
"so that you know how to utilitise ShellBench to "
"its fullest."
)
)
(set #sbguide-askdir-msg
(cat
"\nPlease select the directory "
"to install ShellBench.guide in.\n"
)
)
(set #guide-help
(cat
"AmigaGuide is the Amiga's standard hypertext format.\n\n"
"If you have AmigaOS 3.0 or better, you can use MultiView "
"to read this documentation, otherwise you must use the AmigaGuide "
"program, which is available on AmiNet and Fred Fish disk #870.\n\n"
"Both of these viewer programs have a 'search path', a set "
"of directories they search for AmigaGuide documents. "
"You should place this guide somewhere in that path."
)
)
(set #locale-msg
(cat
"\nShellBench is localized, which means you may use "
"the program in several different languages. "
"Please choose your preferred languages.\n"
)
)
(set #locale-help
(cat
"These are the languages supported by ShellBench.\n\n"
"Simply specify the languages you prefer and the "
"required catalog files will be copied to the "
"Locale:Catalogs directory.\n\nThis feature is "
"only available under AmigaOS 2.1 and later."
)
)
) ; endif xxxx language
)
; ************************************************************************
; Begin actual installation
; ************************************************************************
; Check for KickV37 or better
(if (< (/ (getversion) 65536) 37)
(
(abort #bad-kick-msg)
)
)
; ------------------------------------------------------------------------
; Show welcome msg
(user 2)
(message #hello-msg)
(user old-user-level)
; ------------------------------------------------------------------------
; Ask the user where we should install ShellBench.
(set sbdir
(askdir
(prompt #sb-askdir-msg)
(help @askdir-help)
(default defsbdir)
)
)
; ------------------------------------------------------------------------
; If there is an icon for ShellBench there already, ask the user if we
; should keep it. If yes then copy just the program, else copy both
; the program and icon.
(if (exists (tackon sbdir "ShellBench.info"))
; then
(if (askbool
(prompt #keepicon-msg)
(choices #yes-msg #no-msg)
(help #keepicon-help)
(default 1)
)
; then
(copyfiles (source "ShellBench") (dest sbdir) )
; else
(copyfiles (source "ShellBench") (dest sbdir) (infos) )
)
; else no info there
(copyfiles (source "ShellBench") (dest sbdir) (infos) )
)
(set @default-dest sbdir)
; ------------------------------------------------------------------------
; Install BGUI library. If expert, ask for directory.
(if (= 2 @user-level)
(set libsdir
(askdir
(prompt #bgui-askdir-msg)
(help @askdir-help)
(default libsdir)
)
)
)
(copylib (source "Libs/bgui.library") (dest libsdir)
)
; ------------------------------------------------------------------------
; Install ShellBench.guide. Ask yes/no first, then ask for directory.
; If installed, set GUIDEFILE tooltype of ShellBench.
(set guidedir sbdir)
(if (askbool
(prompt #sbguide-ask-msg)
(help #guide-help)
(default 1)
(choices #yes-msg #no-msg)
)
; then
(
(set guidedir
(askdir
(prompt #sbguide-askdir-msg)
(help @askdir-help)
(default guidedir)
)
)
(copyfiles (source #sbguide) (dest guidedir) (infos) )
(tooltype
(dest (tackon sbdir "ShellBench"))
(settooltype "GUIDEFILE" (tackon guidedir "ShellBench.guide"))
)
)
)
;------------------------------------------------------------------------
; install catalog(s) - none available yet
;
;(if (exists "libs:locale.library")
; (
; (if (exists catsdir)
; (
; (user 2)
; (set lang
; (askoptions
; (prompt #locale-msg)
; (help #locale-help)
; (choices
; "Dansk"
; "Deutsch"
; "English"
; "Español"
; "Français"
; "Italiano"
; "Svenska"
; )
; (default default_lang)
; )
; )
; (user old-user-level)
; (set n 0)
; (while
; (set language
; (select n
; "dansk"
; "deutsch"
; "english"
; "español"
; "français"
; "italiano"
; "svenska"
; ""
; )
; )
; (
; (if (in lang n)
; (
; (if (<> 2 n)
; (
; (makedir (cat catsdir "/" language))
; (copyfiles
; (source (cat "Catalogs/" language))
; (dest (cat catsdir "/" language))
; (all)
; )
; )
; )
; )
; )
; (set n (+ n 1))
; )
; ) ; endwhile pick language n
; ) ; endthen
; ) ; endif exists catsdir
; ) ; endthen
;
;) ; endif exists locale lib